home *** CD-ROM | disk | FTP | other *** search
- dnl Process this file with 'autoconf' to produce a 'configure' script
- dnl $Id: configure.in,v 6.0 1995/03/18 14:22:35 dickey Rel $
- AC_REVISION($Revision: 6.0 $)
- AC_INIT(conflict.c)
-
- AC_ARG_WITH(debugging,
- [ --with-debugging turn on gcc debug-flag ],
- [CFLAGS="$CFLAGS -g"],
- [CFLAGS="$CFLAGS -O"])
-
- AC_PROG_CC
- AC_PROG_INSTALL
- AC_C_CONST
- AC_CHECK_PROGS(LINT, tdlint lint alint)
-
- AC_SUBST(CFLAGS)
- AC_SUBST(LDFLAGS)
- AC_SUBST(LIBS)
- AC_SUBST(LINT)
-
- AC_CONST
- AC_HEADER_STDC
- AC_CHECK_HEADERS(stdlib.h unistd.h)
- AC_CHECK_HEADERS(getopt.h string.h malloc.h sys/param.h)
- AC_HEADER_DIRENT
-
- AC_TYPE_SIZE_T
- AC_CHECK_TYPE(ino_t, unsigned)
- AC_CHECK_TYPE(dev_t, unsigned)
-
- AC_CHECK_FUNCS(getcwd getopt link symlink realpath strrchr strdup)
-
- AC_ARG_WITH(warnings,
- [ --with-warnings turn on gcc warnings, for debugging ],[
- if test -n "$GCC"
- then
- CFLAGS='-O -Wall -Wshadow -Wconversion -Wstrict-prototypes -Wmissing-prototypes'
- fi
- ])
-
- AC_ARG_WITH(dbmalloc,
- [ --with-dbmalloc compile/link with dbmalloc if found ],[
- AC_CHECK_HEADER(dbmalloc.h,[
- AC_CHECK_LIB(dbmalloc,dbmallopt,[
- AC_DEFINE(HAVE_DBMALLOC_H)
- LIBS="$LIBS -ldbmalloc"])])
- ])
-
- ### output makefile and config.h
- changequote({,})dnl
- AC_OUTPUT(makefile config_h,
- {
- echo creating config.h
- sed -e '/^# /d' \
- -e 's/ -D/\
- #define /g' \
- -e 's/\(#define [A-Za-z_][A-Za-z0-9_]*\)=/\1 /g' \
- config_h >config.h
- }
- echo removing config_h
- rm config_h
- )
- changequote([,])dnl
-